home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Communications / Information / high-speed-modem-musings-11.txt < prev    next >
Internet Message Format  |  1994-06-11  |  15KB

  1. Date: Thu, 24 Mar 94 08:45:06 EST
  2. From: iedh1@agt.gmeds.com ( Daniel J. Hofferth   (317)230-4791/Allison Engine Company)
  3. Subject: [*] High Speed Modem Musings (v1.1)
  4.  
  5.  
  6. High Speed Modem Musings (version 1.1)
  7.  
  8. Hi all,
  9.  
  10. I've now spent a number of months with a new V.32bis (14.4K) FAX/modem that
  11. gave me a variety of little fits until I finally got everything running
  12. just right.  Upgrading from a 2400 baud modem, I found I was mentally
  13. unprepared for the many complications introduced by the much higher speeds.
  14. The new modems are NOT always plug-n-play replacements for older models.
  15.  
  16. While quietly researching solutions, I noticed quite a few postings in
  17. different lists/digests (such as this one) from people who are suffering
  18. from problems similar to those I puzzled over.  In the hope of helping
  19. someone else, I posted the problems I had and solutions that worked for me.
  20. Since that first posting in mid-January of '94, I've received a surprising
  21. amount of feedback from others who shared my plight, those who still had
  22. questions, and many offering alternative solutions.  This posting comprises
  23. the original file with all of that feedback folded in.  Thanks to you all!
  24.  
  25. Think these are FAQ's?  Maybe so, but I couldn't find answers in any one
  26. place.  Interesting thing is, these seem like perfectly natural problems
  27. waiting for unsuspecting "slow" modem users who are about to move up.
  28.  
  29.  <As before, I'll say up front that I am no expert!  I am a neophyte.
  30.   Although I've been a professional computer nerd for many years, I
  31.   know almost zip about high speed modems (as I shamelessly prove below).
  32.   Please feel free to comment, clarify, etc...>
  33.  
  34. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  35.  
  36. Before I begin, I had a number of people asking if there was any penalty in
  37. performance for using a modem originally sold for a PC on a Mac.  As far as
  38. I know, aside from packaging, bundled software, and supplied cable, there
  39. is NO difference between a modem sold for a PC and one sold for a Mac.
  40.  
  41. All problems posted below are related to high-speed (HS) communications,
  42. and they occurred while using both CTB and non-CTB applications (Apple's
  43. Communications Tool Box):
  44.  
  45. 1) Trouble establishing a connection.
  46.  
  47.    I had my modem attached to the wall jack via a long (50 feet) ribbon
  48.    style phone cable... the kind where the wires run parallel to each-
  49.    other in a semi-clear casing <what's the official name?>.  To make
  50.    matters worse, it ran in long straight lengths (around an intermediate
  51.    room), and then into a tangle of power cords for the computer.
  52.  
  53.    It was a great antenna, but a lousy HS modem extension.  It worked just
  54.    fine for the 2400 baud modem, mind you.  Went to Radio Shack and picked
  55.    up "twisted pair" phone cable (cheap).  Then rerouted it away from the
  56.    power cords.  Bingo - connections made.
  57.  
  58.    I understand there is also a "high-twist" wire available for data- grade
  59.    communications.  What I bought worked fine for me... my house uses the
  60.    standard twist in the walls... I didn't see any sense in going to data
  61.    grade for just this one length.  They also sell line filters to weed out
  62.    noise - didn't need that either.
  63.  
  64.  
  65. 2) I could now connect at HS with error correction and flow control, and
  66.    work the user-interface without apparent trouble, but file transfers
  67.    kept causing my modem to hang-up abruptly.
  68.  
  69.    The Mac's serial port issues the hardware-handshaking (HH) signal on a
  70.    pin that HH-cables also carry to DTR on the modem.  My modem was set to
  71.    hang-up on loss of DTR (AT &D2), when it should have been told to ignore
  72.    DTR (AT &D0).  No more unexpected hang-ups.  For the older modem, this
  73.    was not an issue - it used Xon/Xoff handshaking.
  74.  
  75.    I've seen postings indicating that some Macs are fast enough to keep up
  76.    with the incoming data flow, no matter how fast it comes in.  For these,
  77.    the messages say, "hang-up on DTR loss" is O.K.  since the Mac will
  78.    never need to use it for flow control.  I'm not lucky enough to own such
  79.    a speed daemon, but this sure sounds like dangerous advice to me....
  80.    What happens when the user pulls down a menu, in mid-file-transfer, and
  81.    lingers there a while deciding what menu item to select?  What happens
  82.    when you're downloading in the background and you launch a BIG program
  83.    from the finder?  Can _nothing_ distract a "fast Mac" long enough to
  84.    force a drop in DTR?  I wonder.  There _are_ other ways to hang-up the
  85.    modem, why tempt fate?
  86.  
  87.  
  88. 3) No more hang-ups, but high speed uploads and downloads were full of
  89.    packet-errors.  Effective throughput was only about 700-800 cps.
  90.  
  91.    I knew that I had a HH-cable, software that had HH support enabled, and
  92.    a modem-to-modem connection that was error correcting and flow
  93.    controlled.  But I was still getting sporadic packet errors on file
  94.    transfers.  Clearly HH wasn't working.
  95.  
  96.    I got out my multi-meter and tested the cable supplied by the modem
  97.    manufacturer.  It WAS a HH-cable, but not wired as suggested by Apple...
  98.    I'm no EE, but it seemed worth swapping out to me.  At my local computer
  99.    store I bought another HH-cable (after being assured that I could return
  100.    it if it didn't work), brought it home and tested it with the meter.
  101.    This one was almost identical to Apple's version except that pin-7 (GPi)
  102.    on the Mac side wasn't connected.  As I gather from other readings, GPi
  103.    is a special purpose pin that isn't used by simple home connectors like
  104.    me.  I tried the new cable, and file transfers were MUCH cleaner, but
  105.    still not perfect.
  106.  
  107.    <Clearly not all HH-cables are appropriate for all machines.  Just
  108.     because your modem manufacturer supplied a cable for you, don't
  109.     assume it is correct for your Mac.  BTW, there are a few Macs that
  110.     don't support HH... the Plus, LC, and Classic, I beleive... and,
  111.     yes, the LC II and Classic II are O.K.>
  112.  
  113.    Here is the HH cable recommended by Apple:
  114.  
  115.                       Mac                 Modem
  116.                       DIN-8               DB-25
  117.  
  118.                       1  HSKo  ------+--  RTS   4
  119.                                      `--  DTR  20
  120.  
  121.                       2  HSKi  ---------  CTS   5
  122.                       3  TxD-  ---------  TxD   2
  123.  
  124.                       4  GND   --+------  GND   7
  125.                       8  RxD+  --'
  126.  
  127.                       5  RxD-  ---------  RxD   3
  128.                       6  TxD+  (nc)
  129.                       7  GPi   ---------  DCD   8
  130.  
  131.                       Shield   ---------  Shield
  132.  
  133.    (Again, remember that the GPi-DCD connection is NOT considered
  134.    essential for normal home connections.  BBS host software only?)
  135.  
  136.  
  137. 4) File transfers still suffered from packet errors if I switched to
  138.    another application, or simply held the mouse button down on a menu.
  139.    Otherwise, they were going O.K.  What now?!
  140.  
  141.    Apple claims the priorities for a variety of system related tasks can
  142.    cause the Mac to miss incoming information.  They suggest the following
  143.    guidelines for improving the CPU's attention to the serial port:
  144.  
  145.       - Limit your Mac-to-modem connection to 19.2KB.
  146.  
  147.         While the new modems can theoretically achieve throughput of up to
  148.         56KB, this is almost NEVER really achieved.  Text file transfers
  149.         can reach 3500 cps (or so), but most file transfering that we do is
  150.         of already compressed files.  Throughput for these is much closer
  151.         to the modem-to-modem implied speed of 1440 cps.  Thus, 19.2KB is
  152.         fast enough for general use.  38.4KB may be safe if you Mac is fast
  153.         enough (mine isn't).
  154.  
  155.       - Don't use 24-bit mode, stick to 32-bit addressing.
  156.  
  157.         24-bit addressing mode apparently peppers the CPU with extra
  158.         interrupts that clouds its ability to watch over the serial port
  159.         flow control... possibly resulting in missed characters.
  160.  
  161.       - Don't use virtual memory.
  162.  
  163.         Same reasoning as above.  The overhead required to manage the
  164.         virtual memory impairs the systems ability to keep up with the
  165.         flood of serial port data.
  166.  
  167.       - Turn off AppleShare.
  168.  
  169.         Again, same reasoning as above.  AppleShare achieves a higher baud
  170.         rate through its serial port by commanding a higher priority level.
  171.  
  172.     I was already at 19.2KB between my Mac and modem (having already
  173.     learned that 38.4KB greatly increased my problems), but I was still in
  174.     24-bit mode with virtual memory on.  I've been pretty religious about
  175.     collecting only 32-bit clean software, and I've got enough real RAM to
  176.     turn VM off without problems, so following these guidelines was
  177.     painless for me.
  178.  
  179.     And they worked.
  180.  
  181. I now have rock-solid high speed connections on a slow Mac, and file
  182. transfers that are robust enough to let me switch between applications
  183. without packet errors.
  184.  
  185. What speeds can be expected?
  186.  
  187.     File transfer speeds, on a full speed (14.4K) connection, HH, with
  188.     hardware compression, etc.  are about 1600 cps when downloading ALREADY
  189.     COMPRESSED files.  I emphasize the "already compressed" part because
  190.     speeds can vary wildly depending on the type of file being transfered
  191.     (some compress better than others).  Very rough numbers range from 3500
  192.     cps for plain ASCII text files to a low of 1440 cps or so, for files
  193.     that won't compress any more at all.  Most everything I download is
  194.     "already compressed" .sit, .cpt, .sea, etc...  On these file types,
  195.     modem compression does very little good, and 1500-1600 cps (give or
  196.     take...) is considered "normal".
  197.  
  198.     Now, these speeds can drop off a little, or even a lot, if you are
  199.     downloading in the background while you are busy in other applica-
  200.     tions--this is perfectly normal.  What should _not_ be happening is
  201.     repeated packet-errors.  Your Mac divvies up its CPU time to all active
  202.     applications, while monitoring the serial port for proper data-flow
  203.     handling.  So long as it isn't distracted too much by higher priority
  204.     interrupts, it'll detect when the serial port buffer is full (because
  205.     your comm program hasn't been given a chance to empty it lately) and
  206.     it'll issue the hardware handshaking signal to tell the modem to pause.
  207.     When the buffer has room again, data transfer is allowed to continue.
  208.     If all is done properly, your comm program will never see a lost or
  209.     incorrect byte (thus, no packet errors), but it will certainly feel the
  210.     overall slow-down due to the shared CPU time with other applications,
  211.     and 1600 cps is enough of a data-flood for this CPU sharing to be felt.
  212.     Faster Macs should do better here.
  213.  
  214. I've done all of that, anything else to watch out for?
  215.  
  216.     I got a number of comments back about various INIT's being CPU hogs
  217.     that can cause trouble.  <Specific names were sparse, just general
  218.     comments.  Please don't Email me for a list, I haven't got one.> I'm
  219.     not convinced this would cause data loss as often as it would cause a
  220.     slow down in effective transfer speed, but clearly the possibility for
  221.     both problems exists.  If you're still having trouble, try temporarily
  222.     rebooting with all non-essential INITs disabled to see if that helps.
  223.  
  224.     This isn't immediately obvious to many, but it makes perfect sense:  If
  225.     process loading on your machine can slow down a file transfer (CPU
  226.     hogging INITs, background downloading with foreground application
  227.     activity, etc.) then it certainly follows that process loading on the
  228.     _host_ you are connected to can also affect that speed.  If you've been
  229.     getting 1600 cps from a given host for months, made no changes to your
  230.     system or transfer procedure, and see an abrupt and significant drop in
  231.     speed...  before you tear your hair out, send a _polite_ note to the
  232.     sysop and ask if he/she is aware of any activity on their end that
  233.     might account for the change.  Be sure to mention the date(s) and
  234.     time(s) of the transfer(s) in question.  If you _have_ made any
  235.     changes, check them out first--sysops work hard enough.
  236.  
  237.     I've heard from some who are _sure_ they have a proper HH cable and
  238.     that their software has been told to use HH, and they still get a lot
  239.     of packet errors while downloading.  Two thoughts here:  The host MAY
  240.     have it wrong, or your modem may not be initialized properly.
  241.  
  242.         Flat out, host problems are unlikely.  Most BBS's and commercial
  243.         services wouldn't last long if they weren't set up right.  Exhaust
  244.         possibilities on your end first before complaining.  If you are
  245.         getting clean file transfers from assorted hosts, but one host
  246.         repeatedly forces packet resends, THEN it's time to consider
  247.         contacting that sysop.
  248.  
  249.         Modem initialization problems are much more likely.  For example...
  250.         Have you told your modem to return the proper response to indicate
  251.         it has a HH connection?  I.E.  instead of "CONNECT 14400", you
  252.         should see "CONNECT 14400/ARQ" when a "reliable" connection is made
  253.         (or "CONNECT 14400/REL" on some modems).  And you may have to tell
  254.         your comm-program what to look for so it knows that such a
  255.         connection has been made ("/ARQ" or "/REL").  On my modem, and
  256.         probably on most, "AT S95=3" enabled this trick.
  257.  
  258.     A final thought on debugging:  I got some feedback from folks who tried
  259.     each of the tips above, one at a time.  In the computer world this is
  260.     often a blindly accepted debugging procedure, but it doesn't always
  261.     make sense.  If you've got your computer-to-modem speed set too high,
  262.     and you've not got a proper HH cable, fixing either one won't work--you
  263.     need to fix both at the same time.  Here's my suggestion...  if you've
  264.     got perplexing connection troubles, change everything between the
  265.     wall-jack and your finger tips that even smells suspicious.  Then, if
  266.     all works well, start restoring anything you'd like to restore...  one
  267.     at a time.
  268.  
  269. By the way, to those of you who wonder about file transfers that abort when
  270. you try to launch a big application, or impose some other long pause...  To
  271. me this doesn't necessarily imply a handshaking error, perhaps the computer
  272. you were connected to decided it had waited long enough and simply
  273. timed-out?  Short pauses should certainly be handled without errors, but
  274. the longer you go - the more likely it is that the host gave up.  No?
  275. (Don't discount the DTR discussion above, item 2)
  276.  
  277. I read one interesting comment from a modem manufacturer...  They noted
  278. that Apple's serial port buffer is painfully small, making the timing on
  279. handshaking a critical and touchy issue.  They noted that as modem speeds
  280. have increased, fortunately so have Mac speeds - thus somewhat
  281. compensating.  Apparently, we slow Mac owners seem to be in the yellow zone
  282. in the war between CPU horsepower and modem data flow.  It doesn't take
  283. much to tip the battle one way or the other.
  284.  
  285. Sorry for the length of this, but I hope it helps someone else.
  286.  
  287.    <Mac Classic II, System 7.1, HSU 2.0.1, 4/40+120, Zoom VFX V.32bis>
  288.  
  289. Dan Hofferth
  290. iedh1@agt.gmeds.com
  291.  
  292.